   <div style="border-bottom:1px solid #e6e6e6;" class="boxleft">
      <div class="boxlefttitle"> <a onclick="jq('#clientClass').show();jq('#brandClass').hide();jq(this).addClass('hot').next().removeClass('hot');" class="hot" href="javascript:void(0);">产品分类</a><a onclick="jq('#clientClass').hide();jq('#brandClass').show();jq(this).addClass('hot').prev().removeClass('hot');" href="javascript:void(0);">品牌分类</a></div>
      <form action="/st71654/product.html" method="post">
        <div class="leftsearch">
          <input type="text" name="Keyword" id="Keyword" onfocus="if(jq.trim(jq(this).val())=='请输入产品关键词...')jq(this).val('');" value="请输入产品关键词...">
          <button onclick="submit()"></button>
        </div>
      </form>
      <div id="clientClass" class="leftlist">
		{dede:field name='typeid' runphp='yes'}
		global $dsql;
		global $brand_id;
		$typeid = @me;
		$query = "select * FROM dede_arctype where id = $typeid";
		$rs = $dsql->GetOne($query);
		$reid = $rs['reid'];
		$topid = $rs['topid'];
		
		if($reid != $topid){
			$x = $rs['reid'];
			$query = "SELECT * from dede_arctype where id = $x";
			$rs = $dsql->GetOne($query);		
		} else {
			$x = $rs['reid'];
			$query = "SELECT * from dede_arctype where reid = $x order by sortrank desc limit 0, 1";
			$rs = $dsql->GetOne($query);			
		}
		
		$link = GetTypeUrl($rs['typeid'],MfTypedir($rs['typedir']),$rs['isdefault'],$rs['defaultname'],$rs['ispart'],$rs['namerule2'],$rs['moresite'],$rs['siteurl'],$rs['sitepath']);
		$id = $rs['id'];
		$brand_id = $rs['id'];
		$typename = $rs['typename'];
		$str = "<dl class='hot' id='dl{$id}'>
		          <dt onclick='showhidedd(\"{$id}\");'><em></em><a title='{$typename}' href='$link'>{$typename}</a></dt>
		          <dd id='dd{$id}'>";
		@me = $str;
		{/dede:field}
		{dede:field name='typeid' runphp='yes'}    
		global $dsql;
		global $brand_id;
		
	    $query2 = "SELECT * FROM dede_arctype where reid = $brand_id order by sortrank";
		$dsql->Execute('me',$query2);
		
		$s = '';
		
		while ($row = $dsql->GetArray('me')) {
			$typename = $row['typename'];
			$link = GetTypeUrl($row['typeid'],MfTypedir($row['typedir']),$row['isdefault'],$row['defaultname'],$row['ispart'],$row['namerule2'],$row['moresite'],$row['siteurl'],$row['sitepath']);
			$s .= "<a href='{$link}' title='$typename'>$typename</a>";
		}
		
		@me = $s;
		{/dede:field} 		
        </dl>      
      </div>
      <div style="display:none" id="brandClass" class="leftlist">
        <table width="100%" cellspacing="2" cellpadding="2" border="0" align="center">
          <tbody>
            <tr>
              <td align="center" class="black4"><strong><br>
                暂无信息<br>
                <br>
                </strong></td>
            </tr>
          </tbody>
        </table>
      </div>
      <h3>公司信息</h3>
      <div class="leftcompany">
        {dede:field name='typeid' runphp='yes'}
		global $dsql;
		$typeid = @me;
		$query = "SELECT * FROM dede_arctype where id = $typeid";
		$rs = $dsql->GetOne($query);
		$topid = $rs['topid'];
		
		$query = "SELECT content FROM dede_arctype where topid = $topid and typename = '公司信息'";
		$rs = $dsql->GetOne($query);		
		@me = $rs['content'];
		{/dede:field}
      </div>
      <script>
            function showhidedd(id) {
                if (jQuery('#dd' + id).is(":hidden")) {
                    jQuery('#dd' + id).show();
                    jQuery('#dl' + id).attr("class", "hot");
                }
                else {
                    jQuery('#dd' + id).hide();
                    jQuery('#dl' + id).attr("class", "");
                }
            }
        </script><br class="clear">
    </div>